//
//  OriginalM.m
//  MixRN
//
//  Created by zsgjs on 2017/2/28.
//  Copyright © 2017年 zsgjs. All rights reserved.
//

#import "OriginalM.h"

@implementation OriginalM

RCT_EXPORT_MODULE()

RCT_EXPORT_METHOD(callPhone:(NSString *)phoneNum)
{
    
    UIAlertController *action = [UIAlertController alertControllerWithTitle:@"拨打电话" message:nil preferredStyle:UIAlertControllerStyleActionSheet];
    UIAlertAction *numAction = [UIAlertAction actionWithTitle:phoneNum style:UIAlertActionStyleDefault handler:nil];
    UIAlertAction *cancelAction = [UIAlertAction actionWithTitle:@"取消" style:UIAlertActionStyleCancel handler:nil];
    [action addAction:numAction];
    [action addAction:cancelAction];
    [[UIApplication sharedApplication].keyWindow.rootViewController presentViewController:action animated:true completion:nil];
}


@end
